from rest_framework import serializers
from apps.recruit.models import Enterprise


# 企业信息
class EnterpriseModelSerializer(serializers.ModelSerializer):
    class Meta: # 默认的字段’recruits'是一查多：recruits = PrimaryKeyRelatedField(many=True, queryset=Recruit.objects.all())
        model = Enterprise
        fields = ('id','name','labels','logo','recruits','summary')


